<ui:composition template="/resources/templates/loginTemplate.xhtml"
                xmlns:h="http://java.sun.com/jsf/html"
                xmlns:f="http://java.sun.com/jsf/core"
                xmlns:ice="http://www.icesoft.com/icefaces/component"
                xmlns:ace="http://www.icefaces.org/icefaces/components"
                xmlns:ui="http://java.sun.com/jsf/facelets">
    <ui:define name="loginContent">
        <f:phaseListener type="ru.compft.web.security.event.LoggedInCheck"/>
        <ace:panel id="loginPanel" header="#{msgs['login_form']}" rendered="true" style="width: 600px; margin: 0 auto; padding: 10px">
            <ice:messages id="loginErrorMessages"/>
            <ice:form id="loginForm">
                <ice:panelGrid columns="2" style="width: 500px">
                    <ice:outputLabel id="userNameLabel" value="#{msgs['user']}:" for="j_username"
                                     style="width: 200px; margin-right: 20px;"/>
                    <ice:inputText id="j_username" value="#{loginFormBean.userName}" style="width:280px;"/>
                    <ice:outputLabel id="passwordLabel" value="#{msgs['password']}:" for="j_password"
                                     style="width: 200px; margin-right: 20px;"/>
                    <ice:inputSecret id="j_password" value="#{loginFormBean.password}" style="width:280px;"/>
                    <ice:outputText value=" "/>
                    <ice:commandButton id="j_submitLogin" value="#{msgs['enter']}"
                                       action="#{loginController.loginUsingSpringAuthenticationManager}"/>
                </ice:panelGrid>
            </ice:form>
        </ace:panel>
    </ui:define>
</ui:composition>
